<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%
	String path = request.getContextPath();
	String basePath = request.getScheme() + "://"
			+ request.getServerName() + ":" + request.getServerPort()
			+ path + "/";
%>
<%@ taglib prefix="tiles" uri="http://tiles.apache.org/tags-tiles"%>

<!doctype html>
<html lang="zh-CN">
<head>
  <meta charset="UTF-8">
  <link rel="stylesheet"
	href="<%=request.getContextPath()%>/resources/css/common.css">
<link rel="stylesheet"
	href="<%=request.getContextPath()%>/resources/css/main.css">
<link rel="stylesheet"
	href="<%=request.getContextPath()%>/resources/css/skin.css">
<link rel="stylesheet"
	href="<%=request.getContextPath()%>/resources/css/search.css">
<link rel="stylesheet"
	href="<%=request.getContextPath()%>/resources/css/basic.css">
<link rel="stylesheet"
	href="<%=request.getContextPath()%>/resources/css/release.css">
<link rel="stylesheet"
	href="<%=request.getContextPath()%>/resources/tree/jquery.treeview.css">
<link rel="stylesheet"
	href="<%=request.getContextPath()%>/resources/css/style.css">
<link rel="stylesheet"
	href="<%=request.getContextPath()%>/resources/baiduditu/carousel.css">
<link rel="stylesheet"
	href="<%=request.getContextPath()%>/resources/css/jquery-ui-1.9.2.custom.min.css">
<script type="text/javascript"
	src="<%=request.getContextPath()%>/resources/js/jquery.min.js"></script>
<script type="text/javascript"
	src="<%=request.getContextPath()%>/resources/js/jquery-ui-1.9.2.custom.js"></script>
<script type="text/javascript"
	src="<%=request.getContextPath()%>/resources/js/jquery.SuperSlide.js"></script>
<script type="text/javascript"
	src="<%=request.getContextPath()%>/resources/js/common.js"></script>
<script type="text/javascript"
	src="<%=request.getContextPath()%>/resources/js/colResizable-1.3.min.js"></script>
<script type="text/javascript"
	src="<%=request.getContextPath()%>/resources/js/hyjs.js"></script>
<script type="text/javascript"
	src="<%=request.getContextPath()%>/resources/tree/demo.js"></script>
<script type="text/javascript"
	src="<%=request.getContextPath()%>/resources/tree/jquery.cookie.js"></script>
<script type="text/javascript"
	src="<%=request.getContextPath()%>/resources/tree/jquery.treeview.js"></script>
<script type="text/javascript"
	src="<%=request.getContextPath()%>/resources/My97DatePicker/WdatePicker.js"></script>
<script type="text/javascript"
	src="<%=request.getContextPath()%>/resources/baiduditu/ditu.js"></script>
<script type="text/javascript"
	src="<%=request.getContextPath()%>/resources/baiduditu/jquery.ui.dialog.js"></script>
<script type="text/javascript"
	src="<%=request.getContextPath()%>/resources/js/admin.js"></script>
<script type="text/javascript"
	src="<%=request.getContextPath()%>/resources/js/carousel.js"></script>
	<script type="text/javascript"
	src="<%=request.getContextPath()%>/resources/layer/layer.js"></script>
	<script type="text/javascript"
	src="<%=request.getContextPath()%>/resources/layer/extend/layer.ext.js"></script>
	<link rel="stylesheet"
	href="<%=request.getContextPath()%>/resources/layer/skin/layer.css">
	<link rel="stylesheet"
	href="<%=request.getContextPath()%>/resources/layer/skin/layer.ext.css">
	<link href="<%=request.getContextPath()%>/resources/lightbox/lightbox.css" rel="stylesheet" type="text/css" />
	<script src="<%=request.getContextPath()%>/resources/lightbox/lightbox.min.js" type="text/javascript"></script>
  <script type="text/javascript">
	$(function() {
	 $.ajaxSetup({  
       async : false  
      });
    
		$(window).resize(function() {
			scrollWW();
		});
        var parentId='${currentNav.parentId}';
        var id='${currentNav.id}';
         $("#tree h3").each(function(){
            if(parentId==$(this).attr("class")){
              $(this).removeClass().addClass("on");
            }
         });
          $("#tree li").each(function(){
            if(id==$(this).attr("class")){
              $(this).removeClass().addClass("on");
            }
         });
         //必须放在动态添加之后
         $(".sideMenu").slide({
			titCell : "h3",
			targetCell : "ul",
			defaultIndex : 0,
			effect : 'slideDown',
			delayTime : '500',
			trigger : 'click',
			triggerTime : '150',
			defaultPlay : true,
			returnDefault : false,
			easing : 'easeInQuint',
			endFun : function() {
				scrollWW();
			}
		});
        
	});
	function scrollWW() {
		if ($(".side").height() < $(".sideMenu").height()) {
			$(".scroll").show();
			var pos = $(".sideMenu ul:visible").position().top - 38;
			$('.sideMenu').animate({
				top : -pos
			});
		} else {
			$(".scroll").hide();
			$('.sideMenu').animate({
				top : 0
			});
			n = 1;
		}
	}

	var n = 1;
	function menuScroll(num) {
		var Scroll = $('.sideMenu');
		var ScrollP = $('.sideMenu').position();
		/*alert(n);
		alert(ScrollP.top);*/
		if (num == 1) {
			Scroll.animate({
				top : ScrollP.top - 38
			});
			n = n + 1;
		} else {
			if (ScrollP.top > -38 && ScrollP.top != 0) {
				ScrollP.top = -38;
			}
			if (ScrollP.top < 0) {
				Scroll.animate({
					top : 38 + ScrollP.top
				});
			} else {
				n = 1;
			}
			if (n > 1) {
				n = n - 1;
			}
		}
	}

	function realSysTime(clock) {
		var now = new Date(); //创建Date对象 
		var year = now.getFullYear(); //获取年份 
		var month = now.getMonth(); //获取月份 
		var date = now.getDate(); //获取日期 
		var day = now.getDay(); //获取星期 
		var hour = now.getHours(); //获取小时 
		var minu = now.getMinutes(); //获取分钟 
		var sec = now.getSeconds(); //获取秒钟 
		month = month + 1;
		var arr_week = new Array("星期日", "星期一", "星期二", "星期三", "星期四", "星期五",
				"星期六");
		var week = arr_week[day]; //获取中文的星期 
		var time = year + "年" + month + "月" + date + "日 " + week + " " + hour
				+ ":" + minu + ":" + sec; //组合系统时间 
		clock.innerHTML = time; //显示系统时间 
	}
	window.onload = function() {
		window.setInterval("realSysTime(clock)", 1000); //实时获取并显示系统时间 
	}
</script>
<title>后台首页</title>
</head>
<body>
	<div class="layout">
		<div class="top">
			<div id="top_t">
				<div id="logo" class="fl"></div>
				<div id="photo_info" class="fr">
					<div id="photo" class="fl">
						<a
							href="<%=request.getContextPath()%>/back/personal/goPersonMes.do"><img
							src="<%=request.getContextPath()%>/resources/images/a.png"
							alt="" width="60" height="60"> </a>
						<div id="gl">
						  <c:if test="${sessionScope.user.role==5}"> 
					平台管理员
				 	 </c:if> 
				 	  <c:if test="${sessionScope.user.role==4}"> 
					 学校管理员
				 	 </c:if>  
						</div>
					</div>
					<div id="base_info" class="fr">
						<div class="help_info">
							<a href="#" id="hp">&nbsp;</a> <a href="#" id="gy">&nbsp;</a> <a
								href="<%=request.getContextPath()%>/back/manager/logout.do" id="out">&nbsp;</a>
						</div>
						<div class="info_center" style="width:300px">
							${sessionScope.user.name}<span  id="nt">通知</span><span><a class = "layer_notice"
								href="javascript:getLayer(this.value);" id="notice" value="">0</a> </span>
						</div>
					</div>
				</div>
			</div>
			<div id="side_here">
				<div id="side_here_l" class="fl"></div>
				<div id="here_area" class="fl">
					当前位置：<span class="fontpink"> <c:if
							test="${currentNav.name !=null }">${currentNav.name}</c:if> <c:if
							test="${currentNav.name ==''||currentNav.name ==null }">首页</c:if>
					</span>
				</div>
				<div id="here_area" class="fr" style="margin-right:2%">
					当前时间：<span id="clock"></span>
				</div>
			</div>
		</div>
		<div class="side">

			<div class="sideMenu" style="margin:0 auto" id="tree">
				  <h3 class="${currentNav.parentId==1 ? 'on' : ''}">活动管理</h3>
				<ul>
					<li class="${currentNav.id==10 ? 'on' : ''}"><a
						href="<%=request.getContextPath()%>/back/actBack/getActivityBeans.do">活动列表</a></li>
						<li class="${currentNav.id==10 ? 'on' : ''}"><a
						href="<%=request.getContextPath()%>/back/actBack/getWorks.do">作品列表</a></li>
					 
				</ul>
				  <h3 class="${currentNav.parentId==2 ? 'on' : ''}">管理员管理</h3>
				<ul>
					<li class="${currentNav.id==20 ? 'on' : ''}"><a
						href="<%=request.getContextPath()%>/back/manager/getManagerList.do">管理员列表</a></li>
					 
				</ul>
				  <h3 class="${currentNav.parentId==3 ? 'on' : ''}">学校管理</h3>
				<ul>
					<li class="${currentNav.id==30 ? 'on' : ''}"><a
						href="<%=request.getContextPath()%>/back/school/query.do">学校列表</a></li>
					 
				</ul>
				 <h3 class="${currentNav.parentId==4? 'on' : ''}">学生管理</h3>
				<ul>
					<li class="${currentNav.id==40 ? 'on' : ''}"><a
						href="<%=request.getContextPath()%>/back/student/query.do">学生列表</a></li>
					 
				</ul>
				 <h3 class="${currentNav.parentId==5 ? 'on' : ''}">老师管理</h3>
				<ul>
					<li class="${currentNav.id==50 ? 'on' : ''}"><a
						href="<%=request.getContextPath()%>/back/teacher/query.do">老师列表</a></li>
					 
				</ul>
				 <h3 class="${currentNav.parentId==6 ? 'on' : ''}">高清资料库</h3>
				<ul>
					<li class="${currentNav.id==60 ? 'on' : ''}"><a
						href="<%=request.getContextPath()%>/back/student/queryzlk.do">资料库列表</a></li>
					 
				</ul>
				 <h3 class="${currentNav.parentId==7 ? 'on' : ''}">字典管理</h3>
				<ul>
					<li class="${currentNav.id==70 ? 'on' : ''}"><a
						href="<%=request.getContextPath()%>/back/dictionary/getDictionaryBeans.do">字典列表</a></li>
					 
				</ul>
				 <h3 class="${currentNav.parentId==8 ? 'on' : ''}">撤销&举报</h3>
				<ul>
					<li class="${currentNav.id==80 ? 'on' : ''}"><a
						href="<%=request.getContextPath()%>/back/revoke/getRevokeBeans.do">撤销列表</a></li>
						<li class="${currentNav.id==81 ? 'on' : ''}"><a
						href="<%=request.getContextPath()%>/back/revoke/getReportlist.do">举报列表</a></li>
				</ul>
				 <h3 class="${currentNav.parentId==9 ? 'on' : ''}">互动管理</h3>
				<ul>
					<li class="${currentNav.id==90 ? 'on' : ''}"><a
						href="<%=request.getContextPath()%>/back/interact/getInteractThemeBeans.do">互动列表</a></li>
					 
				</ul>
				 <h3 class="${currentNav.parentId==110 ? 'on' : ''}">新闻管理</h3>
				<ul>
					<li class="${currentNav.id==111 ? 'on' : ''}"><a
						href="<%=request.getContextPath()%>/back/news/getNewsBeans.do">新闻列表</a></li>
					 
				</ul>
				 <h3 class="${currentNav.parentId==120 ? 'on' : ''}">友情管理</h3>
				<ul>
					<li class="${currentNav.id==121 ? 'on' : ''}"><a
						href="<%=request.getContextPath()%>/back/news/getLinkList.do">友情列表</a></li>
					 
				</ul>
				 <h3 class="${currentNav.parentId==100 ? 'on' : ''}">web配置</h3>
				<ul>
					<li class="${currentNav.id==101 ? 'on' : ''}"><a
						href="<%=request.getContextPath()%>/back/school/set.do?type=4">配置列表</a></li>
					<li class="${currentNav.id==102 ? 'on' : ''}"><a
						href="<%=request.getContextPath()%>/back/news/aboutus.do?type=1">关于我们</a></li>
					<li class="${currentNav.id==103 ? 'on' : ''}"><a
						href="<%=request.getContextPath()%>/back/news/contactus.do?type=2">联系我们</a></li>
					 
				</ul>
			</div>
		</div>
		<div class="main">
			<tiles:insertAttribute name="body"></tiles:insertAttribute>

		</div>

		<div class="scroll">
			<a href="javascript:;" class="per" title="使用鼠标滚轴滚动侧栏"
				onclick="menuScroll(1);"></a> <a href="javascript:;" class="next"
				title="使用鼠标滚轴滚动侧栏" onclick="menuScroll(2);"></a>
		</div>
		<!-- 确认删除 -->
		<div id="deleteToolTip"></div>
		<%-- <div class="bottom">
      <tiles:insertAttribute name="footer"></tiles:insertAttribute>
    </div> --%>
	</div>
</body>
</html>
 

